<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" type="text/css" href="style/admin.css" />
<link rel="stylesheet" type="text/css" href="style/global.css" />
<script type="text/javascript" src="js/jquery.js"></script>
<script src="js/comm.js" type="text/javascript"></script>
<script src="js/ocx.js" type="text/javascript"></script>
<title>无标题文档</title>

</head>

<body>
<script>
var JYPatient = new NYPatient();
JYPatient.id = '-1';
JYPatient.name = '未注册用户';
JYPatient.phone = '<?php echo $phone?>';
</script>
	<div id="wrap">
		<div class="m_head">
			<div class="m_positin">陌生来电</div>
			<div class="m_record">
				您今日已回访 <span class="orange"><b>98</b></span> 位客户，本月已回访 <span
					class="orange"><b>1278</b></span> 位客户
			</div>
			<div class="clear"></div>
		</div>
		<div class="pu_content">
			<div class="cArea">

				<!-- 客户注册 -->
				<script type="text/javascript">
					$(function () {
						// 注册
						$('#regist-unknown-btn').click(function () {
							 JYCsm.form.ajaxPost({formSelector:'#regist-unknown-form',
								 callback: function (rsp, status, xhr) {
									 if (rsp.code > 0) {
										 JYPatient.id = rsp.data.id;
										 JYPatient.name = $('#regist-name').val();
										 // 移除注册按钮
										 $('#regist-unknown-btn').hide();
									 }
								 }
							 });
						     return false;
						});

						// 挂断电话
						$('#btn_hangup').click(function () {
							window.top.JYTopTele.hangUp();
						});
					});
				</script>
				<div class="box">
					<form action="?c=patient&a=regist&sysid=tele" method="post"
						id="regist-unknown-form" name="regist">
						<table class="tabClient" width="0" border="0">
							<tr>
								<th height="37">姓<span class="spacing_one"></span>名：
								</th>
								<td><input class="qu_text" id="regist-name" name="name" type="text" value="匿名用户"/></td>
								<td><input class="btn_gray" name="" id="regist-unknown-btn"
									type="button" value="注 册" /></td>
								<td><input class="btn_hangup" id="btn_hangup" name=""
									type="button" value="" /></td>
							</tr>
							<tr>
								<th height="37">性<span class="spacing_one"></span>别：
								</th>
								<td width="30%"><select class="select" name="sex">
										<option value="男">男</option>
										<option value="女">女</option>
								</select></td>
								<th>电话号码：</th>
								<td width="30%"><input class="qu_text" name="phone"
									value="<?php echo $phone?>" type="text" /></td>
							</tr>
							<tr>
								<th height="37">职<span class="spacing_one"></span>业：
								</th>
								<td><input class="qu_text" name="job" type="text" /></td>
								<td>&nbsp;</td>
								<td>&nbsp;</td>
							</tr>
							<tr>
								<th height="37">身份证号：</th>
								<td colspan="2"><input class="qu_text" name="card" type="text" /></td>
								<td>&nbsp;</td>
							</tr>
							<tr>
								<th height="37">地<span class="spacing_one"></span>址：
								</th>
								<td colspan="3"><input class="qu_text_one" name="address"
									type="text" /></td>
							</tr>
						</table>
					</form>
				</div>

				<!-- 页面提示操作 -->
				<div class="box">
					<h2>陌生来电注意事项：</h2>
					<p class="red">* 便于联系，请询问来电的真实姓名</p>
					<p class="red">* 为了回访方便，请确认对方的电话号码是否可以找到其本人</p>
				</div>

				<!-- 投诉反馈 -->
				<script type="text/javascript">
					$(function () {
						$('input[name="sub_feed"]').click(function () {
							var type = $(this).attr('typeid');
							 JYCsm.form.ajaxPost({formSelector:'#feed-form', data: {type: type, 
								 uid: JYPatient.id, name: JYPatient.name, phone: JYPatient.phone}});
						     return false;
						});
						
						// 动态科室选医生
						$('#feed-dep-select').change(function () {
							var depid = $(this).val();
							$('#feed-doc-select').load('?c=doc&a=selectdocs&depid='+encodeURIComponent(depid)+'&type=MZ');
						});
					});
					
				</script>
				<div class="box">
					<h2>评价反馈</h2>
					<form action="?c=feed&a=feedform" method="post" id="feed-form"
						name="feed_form">
						<table class="tabClient" width="0" border="0">
							<tr>
								<th height="35">科室：</th>
								<td><select class="select" id="feed-dep-select" name="depid">
		<?php 
			if(is_array($alldep) && count($alldep)>0){
				foreach ($alldep as $dep) {
		?>
			<option value='<?php echo $dep['DEP_NO']?>'><?php echo $dep['DEP_NAME']?></option>
		<?php 
				}
			}
		?></select></td>
							</tr>
							<tr>
								<th height="35">医生：</th>
								<td>
								<select class="select" id="feed-doc-select" name="docid">
									<option value="">请先选择科室</option>
								</select>
								</td>
							</tr>
							<tr>
								<th>内容：</th>
								<td><textarea name="content" cols="50" rows="5"></textarea></td>
							</tr>
							<tr>
								<td height="35">&nbsp;</td>
								<td><input class="btn_gray" name="sub_feed" typeid="1" type="button" value="投 诉" />
									<input class="btn_gray" name="sub_feed" typeid="2" type="button" value="建 议" />
									<input class="btn_gray" name="sub_feed" typeid="3" type="button" value="表 扬" />
									<input class="btn_gray" name="sub_feed" typeid="4" type="button" value="其 他" />
								</td>
							</tr>
						</table>
					</form>
				</div>

				<!-- 客户咨询 -->
				<script type="text/javascript">
					$(function () {
						$('#ask-save-btn').click(function () {
							 JYCsm.form.ajaxPost({formSelector:'#ask-form', data: {
								 uid: JYPatient.id, name: JYPatient.name, phone: JYPatient.phone}});
						     return false;
						});
					});
				</script>
				<div class="box">
					<h2>客户咨询</h2>
					<form action="?c=feed&a=askform" method="post" id="ask-form"
						name="ask_form">
						<table class="tabClient" width="0" border="0">
							<tr>
								<th height="35">科室：</th>
								<td>
			<select class="select" id="ask-dep-select" name="depid">
		<?php 
			if(is_array($alldep) && count($alldep)>0){
				foreach ($alldep as $dep) {
		?>
			<option value='<?php echo $dep['DEP_NO']?>'><?php echo $dep['DEP_NAME']?></option>
		<?php 
				}
			}
		?></select></td>
							</tr>
								<tr>
		<th height="35" width="80">标题：</th>
		<td><input type="text" name="title" style="width:200px" class="qi_text" /></td>
	</tr>
							<tr>
								<th>内容：</th>
								<td><textarea name="content" cols="50" rows="5"></textarea></td>
							</tr>
							<tr>
								<td height="35">&nbsp;</td>
								<td><input class="btn_save" id="ask-save-btn" name="ask_save_btn" type="button" /></td>
							</tr>
						</table>
					</form>
				</div>
			</div>
		</div>
	</div>
</body>
</html>